import Vue from 'vue'

import vueRouter from 'vue-router'

// 组件名开头大写
import ShopList from '../components/shopList.vue'
import HelloWorld from '../components/HelloWorld.vue'
import Parent from '../components/parent/index.vue'
import Shop from '../components/shop/index.vue'
import Table from '../components/table.vue'
import tableZSGC from '../components/TableZSGC.vue'
import Crud from '../components/crud.vue'
import TableCrud from '../components/TableCrud.vue'
import FormDemo from '../components/formDemo.vue'
import Login from '../components/login.vue'
import Main from '../components/main.vue'

Vue.use(vueRouter);

const router = new vueRouter({
    routes: [
        {
            path: '/shopList',
            component: ShopList
        },
        {
            path: '/helloWorld',
            component: HelloWorld
        },
        {
            path: '/parent',
            component: Parent,
            name: 'parent'
        },
        {
            path: '/shop',
            component: Shop
        },
        {
            path: '/table',
            component: Table
        },
        {
            path:'/tableZSGC',
            component:tableZSGC
        },
        {
            path:'/crud',
            component:Crud
        },
        {
            path:'/tableCrud',
            component:TableCrud
        },
        {
            path:'/formDemo',
            component:FormDemo
        },
        {
            path:'/login',
            component:Login
        },
        {
            path:'/main',
            component:Main
        },
    ]
})

export default router